﻿<%@ Page Language="VB" MasterPageFile="~/MasterPage.master" AutoEventWireup="false"
    CodeFile="GroupMaintain.aspx.vb" Inherits="WebForm_Manage_GroupMaintain" %>

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <asp:HiddenField ID="hiUID" runat="server" />
            <asp:HiddenField ID="hidbName" runat="server" />
            <asp:Label ID="lblTitle" runat="server" Text=""></asp:Label>
            <asp:ObjectDataSource ID="objDSGroupID" runat="server" 
                SelectMethod="GetGroupIDInsert" TypeName="OAMS.BBL.GroupBBL" 
                UpdateMethod="UpdateGroupID">
                <UpdateParameters>
                    <asp:Parameter Name="GroupID" Type="String" />
                    <asp:Parameter Name="GroupName" Type="String" />
                    <asp:ControlParameter ControlID="hiUID" Name="UID" PropertyName="Value" 
                        Type="String" />
                    <asp:Parameter Name="canModi" Type="Boolean" />
                    <asp:ControlParameter ControlID="hidbName" Name="dbName" PropertyName="Value" />
                </UpdateParameters>
                <SelectParameters>
                    <asp:ControlParameter ControlID="hidbName" Name="dbName" PropertyName="Value" />
                </SelectParameters>
            </asp:ObjectDataSource>
            <TServerControl:TGridView ID="gvGroup" runat="server" AllowHoverEffect="False" 
                AllowHoverSelect="False" AllowPaging="True" 
                DataSourceID="objDSGroupID" ShowFooterWhenEmpty="True" 
                ShowHeaderWhenEmpty="True" SkinID="pager" TotalRowCount="0" Width="400px" 
                AutoGenerateColumns="False" >
                <Columns>
                <asp:TemplateField ItemStyle-Wrap ="False">
                            <EditItemTemplate>
                                <asp:Button ID="btnUpdate" CommandName="Update" runat="server" meta:resourcekey="btnUpdate" />
                                <asp:Button ID="btnCancel" CommandName="Cancel" runat="server" meta:resourcekey="btnCancel" />
                            </EditItemTemplate>
                            <ItemTemplate>
                                <asp:Button ID="btnEdit" CommandName="Edit" meta:resourcekey="btnEdit" runat="server"
                                    Text="Button" />
                            </ItemTemplate>
                        </asp:TemplateField>
                        
                    <asp:TemplateField meta:resourcekey="GroupID">
                        <EditItemTemplate>
                            <asp:TextBox ID="txtGroupID" runat="server" Enabled='<%# Bind("canModi") %>' 
                                Text='<%# Bind("GroupID") %>'></asp:TextBox>
                        </EditItemTemplate>
                        <ItemTemplate>
                            <asp:Label ID="Label1" runat="server" Text='<%# Bind("GroupID") %>'></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField meta:resourcekey="GroupName">
                        <EditItemTemplate>
                            <asp:TextBox ID="txtGroupName" runat="server" Text='<%# Bind("GroupName") %>'></asp:TextBox>
                        </EditItemTemplate>
                        <ItemTemplate>
                            <asp:Label ID="Label2" runat="server" Text='<%# Bind("GroupName") %>'></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateField>
                </Columns>
            </TServerControl:TGridView>
            <br />
        </ContentTemplate>
    </asp:UpdatePanel>
</asp:Content>
